<%#encoding:UTF-8%><div<%= @id && %( id="#{@id}") %> class="<%= ['listingblock',role].compact * ' ' %>"><%
if title? %>
<div class="title"><%= captioned_title %></div><%
end %>
<div class="content code-panel" style="width: 100%; height: auto; border: medium 1px;"><%
nowrap = !(@document.attr? :prewrap) || (option? :nowrap)
if @style == 'source'
  language = attr :language
  code_class = language ? [language, %(language-#{language})] : []
  pre_class = ['highlight']
  pre_lang = nil
  case attr 'source-highlighter'
  when 'coderay'
    pre_class = ['CodeRay']
  when 'pygments'
    pre_class = ['pygments','highlight']
  when 'prettify'
    pre_class = ['prettyprint']
    pre_class << 'linenums' if attr? :linenums
    pre_class << language if language
    pre_class << %(language-#{language}) if language
    code_class = []
  when 'html-pipeline'
    pre_lang = language
    pre_class = code_class = []
    nowrap = false
   when 'codemirror'
     pre_lang = language
     pre_class = ["code programlisting cm-s-neo"]
     code_class = []
     nowrap = false
   end
  pre_class << 'nowrap' if nowrap %>
<pre style="font-size: 16px; font-weight: 100;" <%= pre_class.empty? ? nil : %( class="#{pre_class * ' '}") %><%= pre_lang && %( data-lang="#{pre_lang}") %>><code<%= code_class.empty? ? nil : %( class="#{code_class * ' '}") %>><%= content %></code></pre><%
else %>
<pre<%= nowrap ? ' class="nowrap"' : nil %>><%= content %></pre><%
end %>
</div>
</div>
